package com.lvmama.pangolin.service.impl;

import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.lvmama.pangolin.entity.RuleLevelModel;
import com.lvmama.pangolin.mybatis.mapper.RuleLevelMapper;
import com.lvmama.pangolin.service.RuleLevelService;
@Transactional
@Service
public class RuleLevelServiceImpl implements RuleLevelService{

	/**  
	* @Title：TimeLevelServiceImpl.java
	* @Author:zhoutianqi
	* @Description:
	* @Date：2017年2月23日下午2:24:05  
	*/
	@Autowired
	private RuleLevelMapper timeLevelMapper;
	@Override
	public int insertTimeLevel(RuleLevelModel timeLevel) throws Exception {
		return timeLevelMapper.insertTimeLevel(timeLevel);
	}

	@Override
	public List<RuleLevelModel> getOpenTimeLevel(Map<String, Object> map) throws Exception {
		return timeLevelMapper.getOpenTimeLevel(map);
	}
	public int updteTimeLevel(RuleLevelModel timeLevel)throws Exception{
		return timeLevelMapper.updteTimeLevel(timeLevel);
	}
	public int deleteLevelByID(int id)throws Exception{
		return timeLevelMapper.deleteLevelByID(id);
	}
	
	@Override
	public List<RuleLevelModel> getTimeLevel(RuleLevelModel timeLevel) {
		return timeLevelMapper.getTimeLevel(timeLevel);
	}	

	@Override
	public List<RuleLevelModel> getNormalLevel() {
		return timeLevelMapper.getNormalLevel();
	}

	@Override
	public List<RuleLevelModel> getSuperLevel() {
		return timeLevelMapper.getSuperLevel();
	}
}
